clear; clc;
%% device prepare
ziCreateAPISession('dev3538', 6);
s=MeasurementSession.SimpleMeasurement();

tek=s.getDevice('tek');

aom = EquipmentControl.ExecutionEquipment.AOM.AA('Pol Beam');
aom.controlledBy(tek, 1);
%%
xMag=1.5;
ziDAQ('setDouble', '/dev3538/auxouts/1/offset',xMag);
for i=1:5
aom.dcON;
pause(100);
aom.dcOFF;
rigol.forceTrigger;
pause(5);
aom.dcON;
end